package com.atguigu.cloud.entities;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.math.BigDecimal;
import javax.persistence.*;

/**
 * 表名：order
*/
@Schema(title = "订单表")
@Table(name = "ordertable")
@TableName("ordertable")
@AllArgsConstructor
@NoArgsConstructor
@Data
public class Order {
    @TableId
    @GeneratedValue(generator = "JDBC")
    @Schema(title = "订单id")
    private Integer orderid;

    @Schema(title = "用户id")
    private Integer userid;

    @Schema(title = "日期")
    private String  data;

    @Schema(title = "总价")
    private BigDecimal totalprice;

    @Schema(title = "状态")
    private String state;

    @Schema(title = "商品")
    private String products;

    /**
     * @return orderid
     */
    public Integer getOrderid() {
        return orderid;
    }

    /**
     * @param orderid
     */
    public void setOrderid(Integer orderid) {
        this.orderid = orderid;
    }

    /**
     * @return userid
     */
    public Integer getUserid() {
        return userid;
    }

    /**
     * @param userid
     */
    public void setUserid(Integer userid) {
        this.userid = userid;
    }

    /**
     * @return data
     */
    public String getData() {
        return data;
    }

    /**
     * @param data
     */
    public void setData(String data) {
        this.data = data;
    }

    /**
     * @return totalprice
     */
    public BigDecimal getTotalprice() {
        return totalprice;
    }

    /**
     * @param totalprice
     */
    public void setTotalprice(BigDecimal totalprice) {
        this.totalprice = totalprice;
    }

    /**
     * @return state
     */
    public String getState() {
        return state;
    }

    /**
     * @param state
     */
    public void setState(String state) {
        this.state = state;
    }

    /**
     * @return products
     */
    public String getProducts() {
        return products;
    }

    /**
     * @param products
     */
    public void setProducts(String products) {
        this.products = products;
    }
}